﻿<%@ Page Language="C#" AutoEventWireup="true" CodeFile="myaccount.aspx.cs" Inherits="myaccount" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<script runat="server">

</script>
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
 <script type="text/javascript">

     function displayCalendar() {
         var datePicker = document.getElementById('datePicker');
         datePicker.style.display = 'block';
     }
    
    </script>
<script type="text/javascript">


    function MM_preloadImages() { //v3.0
        var d = document; if (d.images) {
            if (!d.MM_p) d.MM_p = new Array();
            var i, j = d.MM_p.length, a = MM_preloadImages.arguments; for (i = 0; i < a.length; i++)
                if (a[i].indexOf("#") != 0) { d.MM_p[j] = new Image; d.MM_p[j++].src = a[i]; } 
        }
    }
    function MM_findObj(n, d) { //v4.01
        var p, i, x; if (!d) d = document; if ((p = n.indexOf("?")) > 0 && parent.frames.length) {
            d = parent.frames[n.substring(p + 1)].document; n = n.substring(0, p);
        }
        if (!(x = d[n]) && d.all) x = d.all[n]; for (i = 0; !x && i < d.forms.length; i++) x = d.forms[i][n];
        for (i = 0; !x && d.layers && i < d.layers.length; i++) x = MM_findObj(n, d.layers[i].document);
        if (!x && d.getElementById) x = d.getElementById(n); return x;
    }
    function MM_swapImage() { //v3.0
        var i, j = 0, x, a = MM_swapImage.arguments; document.MM_sr = new Array; for (i = 0; i < (a.length - 2); i += 3)
            if ((x = MM_findObj(a[i])) != null) { document.MM_sr[j++] = x; if (!x.oSrc) x.oSrc = x.src; x.src = a[i + 2]; }
    }
    function MM_swapImgRestore() { //v3.0
        var i, x, a = document.MM_sr; for (i = 0; a && i < a.length && (x = a[i]) && x.oSrc; i++) x.src = x.oSrc;
    }




</script>
 <script type="text/javascript">
     function showInsert() {
         var divInsert = document.getElementById('divInsert');
         divInsert.style.display = 'block';
     }
 </script>
 <script type="text/javascript">
     function showInsert1() {
         var divInsert1 = document.getElementById('divInsert');
         divInsert1.style.display = 'none';
     }
 </script>
 <style type="text/css">
        #datePicker
        {
            display:none;
            position:absolute;
            border:solid 2px black;
            background-color:white;
           
        }
    
    </style>

<style type="text/css">
html
{
  background-image:url('image/back.jpg'); 

    padding:10px;
    color:White;    
  
}
.footer
{

   margin-top:250px;
}
.content
{
    width:950px;
    margin:auto;
        height: 197px;
    }
a
{
 color: white;
 text-decoration:none;

}
a:hover
{
 color: red; 
  text-decoration:none;

}
.link
{
  margin-left:350px; 
     font-weight:bold;
  font-size:large;  
    font-size:x-large;
}
.link2
{
  margin-left:50px; 
     font-weight:bold;
  font-size:large;  
    font-size:x-large;
}
.join
{
   background-color:#0099FF;
  clip:auto;
  font-weight:bold;
  font-size:large;
}
.table2
{
 border-style:solid;
   border-color:Black;
   background-color:White;
   color:Black;  
   width:900px; 
}
.row
{
   background-color:Gray;
   color:White;
}
.ticket
{
   background-color:#CC0000;
color:White;

}

.ticket:hover
{
 color: black; 
  text-decoration:none;


}
    .style1
    {
        width: 509px;
    }
    
.footer
{

     font-weight:bold;
  font-size:large;  

}
.session
{

  background-color:#F4F4F4;   
}
.session2
{
    
 margin-top:30px;
 margin-left:180px;
}
.cancel
{
    
 padding-left:50px;
}
 #divInsert
        {
            display:none;
            border:solid 1px black;
            width:220px;
            height:250px;
            position:absolute;
            top:150px;
            left:400px;
            padding:10px;
            background-color:white;
            color:Black;
        }
          #footer {
        position: fixed;
        width: 100%;
        height: 100px;
        top: auto;
        right: 0;
        bottom: 0;
        left: 0;
        padding-left:150px;
      }
</style>
    <title>My account</title>
</head>
<body>
    <form id="form1" runat="server">
  <div class="content">
  <asp:Image ID="Image1" Width="1000" Height="130" ImageUrl="~/image/tdk-jun5-bannerbatmanexclusivo2.jpg" runat="server" />
<asp:HyperLink ID="HyperLink14"  CssClass="link" NavigateUrl="~/Default.aspx" runat="server">Home</asp:HyperLink>
<asp:HyperLink ID="HyperLink1"  CssClass="link2" NavigateUrl="~/Session.aspx" runat="server">Session</asp:HyperLink> <asp:HyperLink ID="HyperLink2" CssClass="link2" NavigateUrl="~/Movie.aspx" runat="server">Movies</asp:HyperLink>
<asp:HyperLink ID="HyperLink3" CssClass="link2"  NavigateUrl="~/Price.aspx" runat="server">Prices</asp:HyperLink>
<asp:HyperLink ID="HyperLink6" CssClass="link2"  NavigateUrl="~/register.aspx" runat="server">Register</asp:HyperLink>
 <br /> <br />
      
  
 <table >
 <tr><td><asp:Label ID="Label6" runat="server"  ForeColor="Yellow" Text="Buy Tickets For:" Font-Bold="True"></asp:Label>  </td> <td>  <asp:Menu
        id="menuTabs"
      StaticMenuItemStyle-BackColor="#333333" 
        StaticMenuItemStyle-Font-Size="Larger"
       DynamicHorizontalOffset="0"   
      DynamicHoverStyle-BackColor="#666666"
        DynamicMenuItemStyle-Width="150px"
       DynamicMenuItemStyle-BackColor="#333333" runat="server">
       <Items>
       <asp:MenuItem
       Text="Cinemas" Selectable="False"  >
     <asp:MenuItem
       Text="Southwestcinema4"
   
        NavigateUrl="~/MovieCinema1.aspx" />
    <asp:MenuItem
      Text="RuralTwinCinemas"
     NavigateUrl="~/MovieCinema2.aspx" />
   </asp:MenuItem>
       </Items>
       </asp:Menu></td><td>&nbsp;&nbsp;&nbsp;&nbsp&nbsp;&nbsp&nbsp;&nbsp&nbsp&nbsp;&nbsp &nbsp&nbsp;&nbsp&nbsp;&nbsp;&nbsp;&nbsp&nbsp;&nbsp&nbsp;&nbsp&nbsp&nbsp;&nbsp &nbsp&nbsp;&nbsp</td><td> <asp:Label ID="Label4" runat="server" Text="Label"></asp:Label></td>
<td>&nbsp;&nbsp;&nbsp;&nbsp&nbsp;&nbsp&nbsp;&nbsp&nbsp&nbsp;  <asp:Label ID="Label5" runat="server" Text="UserName:" Font-Bold="True"></asp:Label>  <asp:LoginName ID="LoginName1" runat="server" /> &nbsp;&nbsp;<asp:HyperLink ID="HyperLink15"   Font-Bold="True" Font-Underline="True" runat="server"  ForeColor="Yellow" />&nbsp;&nbsp;
    <asp:LoginStatus ID="LoginStatus1" runat="server" />
</td>
<td></td>
</tr>
  </table>
   <br />
      <asp:Label ID="Label1"   runat="server" Visible="false" ></asp:Label>
      <asp:ScriptManager ID="ScriptManager1" runat="server" />
      <asp:UpdatePanel ID="UpdatePanel1" runat="server">
      <ContentTemplate>
      <div>
      <asp:GridView ID="GridView1"  DataSourceID="SqlDataSource1" runat="server" 
         AutoGenerateColumns="False"    DataKeyNames="OrderId" HorizontalAlign="Left">
          <Columns>
          <asp:CommandField ShowSelectButton="true" SelectText="More details" HeaderStyle-Font-Overline="true" />
<asp:BoundField DataField="orderid" HeaderText="Receipt Number"     HeaderStyle-ForeColor="#FFFFCC" />
 <asp:BoundField DataField="OrderDate" HeaderText="OrderDate"  HeaderStyle-ForeColor="#FFFFCC"  DataFormatString="{0:dd/MM/yyyy}" HeaderStyle-Font-Overline="true" />
  <asp:BoundField DataField="title" HeaderText="Title"  HeaderStyle-ForeColor="#FFFFCC"  />
 <asp:BoundField DataField="theatre" HeaderText="Theatre"  HeaderStyle-ForeColor="#FFFFCC"  />
  <asp:BoundField DataField="cinema" HeaderText="Cinema"  HeaderStyle-ForeColor="#FFFFCC"  />
    <asp:BoundField DataField="SESSIONDATE" HeaderText="date" DataFormatString="{0:dd/MM/yyyy}"  HeaderStyle-ForeColor="#FFFFCC" />
      <asp:BoundField DataField="sessiontime" HeaderText="Time" DataFormatString="{0:hh:mm}"  HeaderStyle-ForeColor="#FFFFCC" />        
       <asp:BoundField DataField="amountpaid" HeaderText="Amount Paid" DataFormatString="{0:c}"  HeaderStyle-ForeColor="#FFFFCC" />
          </Columns>
      </asp:GridView>
  

    
           <asp:GridView ID="GridView2" ShowFooter="True"  AutoGenerateColumns="False"  
              BorderStyle="None"  DataSourceID="SqlDataSource2" runat="server" 
              HorizontalAlign="Center">
   <Columns>
   <asp:TemplateField ItemStyle-BorderStyle="None" HeaderStyle-BorderStyle="None">
   <HeaderTemplate>
 <tr><th style="text-decoration: underline; color: #FFFFCC;">More Details </th> </tr>
 </HeaderTemplate>
   <ItemTemplate>
     <asp:Label ID="Label2" runat="server" Text="Total of tickets: " Font-Bold="True"></asp:Label> <%#Eval("totalticket")%> <br />
 <asp:Label ID="Label3" runat="server" Text="Total of Adult tickets: " Font-Bold="True"></asp:Label> <%#Eval("numadult")%> <br />
  <asp:Label ID="Label7" runat="server" Text="Total of Children tickets: " Font-Bold="True"></asp:Label> <%#Eval("numchild")%> <br />
  <asp:Label ID="Label8" runat="server" Text="Total of Senior tickets: " Font-Bold="True"></asp:Label> <%#Eval("numsenior")%> <br />
    <asp:Label ID="Label9" runat="server" Text="Total of Student tickets: " Font-Bold="True"></asp:Label> <%#Eval("numstudent")%> <br />
     <asp:Label ID="Label10" runat="server" Text="Total of Pensioner tickets: " Font-Bold="True"></asp:Label> <%#Eval("numpensioner")%> <br />
      <asp:Label ID="Label11" runat="server" Text="Ticket Type: " Font-Bold="True"></asp:Label> <%#Eval("tickettype")%> <br />
       <asp:Label ID="Label12" runat="server" Text="Credit Card Type: " Font-Bold="True"></asp:Label> <%#Eval("creditcardtype")%> <br />
        <asp:Label ID="Label13" runat="server" Text="Name Card: " Font-Bold="True"></asp:Label> <%#Eval("namecard")%> <br />
        <asp:Label ID="Label14" runat="server" Text="Card Number: " Font-Bold="True"></asp:Label> <%#Eval("cardnumber")%> <br />
         <asp:Label ID="Label15" runat="server" Text="Expire Date: " Font-Bold="True"></asp:Label> <%#Eval("expiredate")%> <br />
 </ItemTemplate> 
 <FooterTemplate >

 
 </FooterTemplate> 

<HeaderStyle BorderStyle="None"></HeaderStyle>

<ItemStyle BorderStyle="None"></ItemStyle>
   </asp:TemplateField>      
          </Columns>
  
           
           </asp:GridView>    
       </div>
 <asp:SqlDataSource ID="SqlDataSource2" runat="server" 
               ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
               
          SelectCommand="SELECT orderid, CustomerUserName, numadult, numchild, numsenior, numstudent, numpensioner, tickettype, creditcardtype, namecard, cardnumber, expiredate, totalticket FROM Ordertotal WHERE (CustomerUserName = @CustomerUserName) AND (orderid = @orderid)">
     <SelectParameters>
         <asp:ControlParameter ControlID="Label1" Name="CustomerUserName" 
             PropertyName="Text" Type="String" />
             
                      <asp:ControlParameter ControlID="GridView1" Name="orderid" 
             PropertyName="Selectedvalue"  />
     </SelectParameters>
           </asp:SqlDataSource>   

       
      <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
          ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
          
               
               
          
          SelectCommand="SELECT orderid, CustomerUserName, OrderDate, theatre, title, cinema, sessiondate, sessiontime, AmountPaid FROM Ordertotal WHERE (CustomerUserName = @CustomerUserName)">
          <SelectParameters>
              <asp:ControlParameter ControlID="Label1" Name="CustomerUserName" 
                  PropertyName="Text" Type="String" />
          </SelectParameters>
      </asp:SqlDataSource> 
      
      </ContentTemplate>
      </asp:UpdatePanel>
                <div id="footer">
  <table width="100" cellpadding="15" ><tr><td>Copyright@2012 MovieTix</td><td><asp:HyperLink ID="HyperLink8"  CssClass="footer" NavigateUrl="~/Default.aspx" runat="server">Homepage</asp:HyperLink></td><td><asp:HyperLink ID="HyperLink9"  CssClass="footer" NavigateUrl="~/Session.aspx" runat="server">Session</asp:HyperLink></td><td><asp:HyperLink ID="HyperLink10"  CssClass="footer" NavigateUrl="~/Movie.aspx" runat="server">Movies</asp:HyperLink></td><td><asp:HyperLink ID="HyperLink12"  CssClass="footer" NavigateUrl="~/register.aspx" runat="server">Register</asp:HyperLink></td><td><asp:HyperLink ID="HyperLink13"  CssClass="footer" NavigateUrl="~/Login.aspx" runat="server">Log In</asp:HyperLink></td></tr></table>
</div>      
    
    </form>

</body>
</html>
